package visitor

import "fmt"

type Company struct {
	Name string
}

func (c Company) Visit(user *User) {
	user.VisitCompany()
}

type Shop struct {
	Name string
}

func (s Shop) Visit(user *User) {
	user.VisitShop()
}

type School struct {
	Name string
}

func (s School) Visit(user *User) {
	user.VisitSchool()
}

type Assess interface {
	Visit(user *User)
}

type User struct {
}

func (user *User) VisitCompany() {
	fmt.Println("用户参观了公司")
}
func (user *User) VisitShop() {
	fmt.Println("用户参观了店铺")

}
func (user *User) VisitSchool() {
	fmt.Println("用户参观了学校")

}
